package com.rickpan.dto.contacts;

import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.Size;

/**
 * 发送好友申请请求DTO
 */
public class SendFriendRequestRequest {

    @NotNull(message = "目标用户ID不能为空")
    private Long toUserId;

    @Size(max = 200, message = "申请消息长度不能超过200个字符")
    private String message;

    // 构造函数
    public SendFriendRequestRequest() {}

    public SendFriendRequestRequest(Long toUserId) {
        this.toUserId = toUserId;
    }

    public SendFriendRequestRequest(Long toUserId, String message) {
        this.toUserId = toUserId;
        this.message = message;
    }

    // Getter和Setter方法
    public Long getToUserId() {
        return toUserId;
    }

    public void setToUserId(Long toUserId) {
        this.toUserId = toUserId;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    @Override
    public String toString() {
        return "SendFriendRequestRequest{" +
                "toUserId=" + toUserId +
                ", message='" + message + '\'' +
                '}';
    }
}
